<template>
    
  <!-- <div class="home">
    <img alt="Vue logo" src="../assets/logo.png" />
    <HelloWorld msg="Welcome to Your Vue.js + TypeScript App" />
  </div> -->
  <div>msg-{{msg}}</div>
  <div>msg2-{{msg2}}</div>
  <slot name="aaa" :msg="msg"></slot>
  <button @click="fn"></button>
</template>

<script lang="ts">
import { defineComponent } from "vue";


export default defineComponent({
  props:['msg'],
  emits:["custom-event"],
  setup(props,{attrs,slots,emit},){
    console.log(props,attrs,slots,emit)
    const fn=()=>{
        emit("custom-event","111")
    }
    return{
     msg2:attrs.msg2,
     fn
    }
  }
});
</script>

